package com.jinsi.controller.yrf;
import com.jinsi.pojo.SyFabsCollectCensus;
import com.jinsi.service.yrf.FabulousCensusService;
import com.jinsi.util.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;

/**
 * 商品课程点赞收藏统计
 * @author 86185
 * @date 2022/10/24
 */
@RestController
@RequestMapping("/fabCensus")
public class FabulousCensusController {

    @Autowired
    private FabulousCensusService fabulousCensusService;

    /**
     * 商品点赞收藏
     * @return 表格数据
     */
    @RequestMapping("/getCommTab")
    public R getCommTab(){

        List<SyFabsCollectCensus> all = fabulousCensusService.getCommTab();
        System.out.println(all);
        return R.ok(all);
    }

    /**
     * 课程点赞收藏
     * @return 表格数据
     */
    @RequestMapping("/getCurrTab")
    public R getCurrTab(){

        List<SyFabsCollectCensus> all = fabulousCensusService.getCurrTab();
        System.out.println(all);
        return R.ok(all);
    }
}
